package com.naiterui.ehp.bs.ds.common.json;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

import com.fasterxml.jackson.annotation.JacksonAnnotationsInside;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;

@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.FIELD, ElementType.METHOD})
@JacksonAnnotationsInside
@JsonSerialize(using = UrlFieldSerializer.class)
public @interface Url {
    /**
     * 如果设置host，那么不会获取config
     *
     * @return
     */
    String host() default "";

    /**
     * 读取配置
     *
     * @return
     */
    String config();

    String code();
}
